package demo;

public class Main {
    public static void main(String[] args) {
        System.out.println("=== 校园信息系统 ===");
        System.out.println();

        // 创建学生对象
        Student student1 = new Student("2024001", "张三", "男", 20);
        Student student2 = new Student("2024002", "李四", "女", 19);

        // 创建课程对象
        Course course1 = new Course("C001", "Java程序设计", "王教授");
        Course course2 = new Course("C002", "数据结构", "刘教授");

        // 修改学生信息
        System.out.println("修改学生信息...");
        student1.setAge(21);

        // 修改课程信息
        System.out.println("修改课程信息...");
        course2.setTeacher("赵教授");

        System.out.println();

        // 显示学生信息
        student1.showInfo();
        student2.showInfo();

        // 显示课程信息
        course1.showInfo();
        course2.showInfo();
    }
}
